/******************************************************
  File: include/msgcodes.h
  Description: Audio Cup Message Codes Loop ( header )
  Author: Brant Anderson
  Date: 10/29/01
  Last Update: 10/29/01
  Status: Not Started
  To Do:
 ******************************************************/



#include "lcd/sockets.h"
#include "xaudio/player.h"

#ifndef SONGINFO
 #define SONGINFO
 #define MP3 10
 #define OGG 20
 typedef struct {
     int scroller;
     char artist[64];
     char album[64];
     char track[64];
     char title[64];
     
     char *playlist;
     char *filename;
     int ctype;
     int songnum;
     int loop;
 } SongInfo;
#endif

#ifndef GENERIC_CONTROL_FUNCTIONS
 #define GENERIC_CONTROL_FUNCTIONS
 /**** Generic Player Control Functions ****/
 int getCount( char *playlist );
 char *getSong( char *playlist, int songnum );
 SongInfo getSongInfo( SongInfo songinf );
 int openSong( SongInfo songinf, char *filename );
 int playSong( int ctype );
 int pauseSong( int ctype );
 int stopSong( int ctype );
 int seekSong( int ctype, unsigned short offset );
 int closePlayer( int ctype );
 /* Need to make this generic... */
 int getMessage( int ctype, XA_Message *xaMessage );
 /**** Display Key-Press Stuff ****/
 void menuDisplay( SongInfo songinf );
#endif


SongInfo keySignal( int sock, SongInfo songinf );
SongInfo right_signal_connect( SongInfo songinf );
void menuDisplayTime( unsigned char min, unsigned char sec, unsigned long dur );
